home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Language/OS - Multiplatform Resource Library
/
LANGUAGE OS.iso
/
et
/
et3_0-a1.lha
/
et3
/
src
/
Expander.C
< prev
next >
Wrap
C/C++ Source or Header
|
1992-05-05
|
1KB
|
69 lines
#ifdef __GNUG__
#pragma implementation
#endif
#include "Expander.h"
#include "Class.h"
//---- Expander ----------------------------------------------------------------
NewMetaImpl0(Expander, Box);
Expander::Expander(int id, Direction d, Point g)
: Box(id, gPoint0, g, (VObjAlign)0)
{
Init(d);
}
Expander::Expander(int id, Direction d, Point g, VObject *va_(vop), ...)
: Box(id, gPoint0, g, (VObjAlign)0)
{
va_list ap;
va_start(ap,va_(vop));
SetItems(va_(vop), ap);
Init(d);
va_end(ap);
}
Expander::Expander(int id, Direction d, Point g, SeqCollection *c)
: Box(id, gPoint0, g, (VObjAlign)0, c)
{
Init(d);
}
void Expander::Init(Direction d)
{
if (d == eVert) {
align= (VObjAlign)(eVObjHLeft|eVObjVExpand|eVObjHExpand);
colsrows.x= 1;
} else {
align= (VObjAlign)(eVObjVTop|eVObjVExpand|eVObjHExpand);
colsrows.y= 1;
}
}
//---- HExpander ---------------------------------------------------------------
HExpander::HExpander(Point g, VObject *va_(vop), ...)
: Expander(cIdNone, eHor, g, (SeqCollection*)0)
{
va_list ap;
va_start(ap,va_(vop));
SetItems(va_(vop), ap);
va_end(ap);
}
//---- VExpander ---------------------------------------------------------------
VExpander::VExpander(Point g, VObject *va_(vop), ...)
: Expander(cIdNone, eVert, g, (SeqCollection*)0)
{
va_list ap;
va_start(ap,va_(vop));
SetItems(va_(vop), ap);
va_end(ap);
}